<!--<table class="customers-table">
  <tr>
    <td style="width: 70px;">
      ابحث عن
    </td>
    <td style="width: 6px;">
      :
    </td>
    <form name="searh-clients" id="search-clients" method="POST" action="">
    <td style="width: 120px;">
      <input type="email" class="small-input" name="search" id="from" />
    </td>
    <td style="width: 10px">
    </td>
		<td style="width: 100px">
      <input id="radio1" name="search-choice" value="0" checked="checked" type="radio">
      <label for="RadioButtonList1_0">رقم الإثبات</label>
    </td>
    <td style="width: 100px">
    <input id="RadioButtonList1_2" name="search-choice" value="1" type="radio">
    <label for="RadioButtonList1_2">جوال</label>
    </td>
    <td style="width: 100px"><div style="margin-top:0;float:none" class="search-botton">بحث</div>  </td>
    </form>
  </tr>
</table> -->
      <table class="customers-table">
          <tr class="customers-table-head">
            	<td width="160px"> اسم الشركة </td>
                <td width="140px"> الخصم </td>
                <td width="100px"> هاتف الشركة </td>
                <td width="100px">الشخص المسئول </td>
                <td width="110px">العمليات</td>
            </tr>
           
                <?php if(!empty($companies)) { ?>
                <?php foreach($companies as $company) {?>
                <?php $client_name = query("SELECT name from clients where id = ?",$company['representative_id']); ?>
                <tr class="cell-parent">
                    <td id="company-name"><?php echo $company['company_name']; ?>  </td>
                    <td id="discount" ><?php echo $company['discount_for_company'] ;?></td>
                    <td ><?php echo $company['company_phone'] ;?></td>
                    <td class="client_name" ><?php echo $client_name[0]['name'] ;?></td>
                    <td ><a href="#" style="color:#000" class="chosen-company" id="<?php echo $company['representative_id']; ?>">أختر</a></td>
                </tr>
                <?php  }
                }else{
                  echo "<td colspan='5' class='red large' align=''>لا توجد نتائج</td>";
                } ?>
              
        </table>
